import request from '@/utils/request'

// 查询财务核心-科目管理列表
export function listFinSubjectManage(query) {
  return request({
    url: '/subjectManage/finSubjectManage/list',
    method: 'get',
    params: query
  })
}

// 查询财务核心-科目管理详细
export function getFinSubjectManage(id) {
  return request({
    url: '/subjectManage/finSubjectManage/' + id,
    method: 'get'
  })
}

// 保存财务核心-科目管理
export function saveFinSubjectManage(data) {
  return request({
    url: '/subjectManage/finSubjectManage/save',
    method: 'post',
    data: data
  })
}

// 删除财务核心-科目管理
export function delFinSubjectManage(id) {
  return request({
    url: '/subjectManage/finSubjectManage/' + id,
    method: 'delete'
  })
}

// 导出财务核心-科目管理
export function exportFinSubjectManage(query) {
  return request({
    url: '/subjectManage/finSubjectManage/export',
    method: 'get',
    params: query
  })
}

// 下拉树
export function getSubjectSelectTree() {
  return request({
    url: '/subjectManage/finSubjectManage/getSelectTree',
    method: 'get'
  })
}

// 保存保障房台账管理信息
export function checkSubjectCodeManager(data) {
  return request({
    url: '/subjectManage/finSubjectManage/checkSubjectCodeManager',
    method: 'post',
    data: data
  })
}

// 获取tree
export function getSubjectTreeData(query) {
  return request({
    url: '/subjectManage/finSubjectManage/getTreeData',
    method: 'get',
    params: query
  })
}
